package com.flying.flow.model;

import com.flying.framework.annotation.Param;
import com.flying.framework.annotation.Property;
import com.flying.framework.data.Data;
import com.flying.framework.data.DataSerializable;
import com.flying.framework.metadata.Meta;

@SuppressWarnings("serial")
@Meta(id="f_node_transition",title="", table="f_node_transition", primaryKeys={})
public class NodeTransition extends Data implements DataSerializable {
	public final static String ENTITY_NAME = "f_node_transition";

	public final static String NAME = "name";
	public final static String REMARKS = "remarks";
	public final static String FLOW_DEF_ID = "flow_def_id";
	public final static String FROM_NODE_ID = "from_node_id";
	public final static String TO_NODE_ID = "to_node_id";
	public final static String CONDITION = "through_condition";

	
	@Param(value=NAME,   required=true,   maxlength=100,	desc="名称" )
	private String name;
	
	@Param(value=REMARKS,   required=false,   maxlength=1000,	desc="说明" )
	private String remarks;
	
	@Param(value=FLOW_DEF_ID,   required=true,   maxlength=0,	desc="流程定义ID" , 
			props= {@Property(name="type",value="hidden")})
	private Long flowDefId;

	@Param(value=FROM_NODE_ID,   required=true,   desc="起始节点" )
	private Long fromNodeId;
	
	@Param(value=TO_NODE_ID,   required=true,   desc="终止节点" )
	private Long toNodeId;

	@Param(value="from_node_name",   ignored=true,   desc="起始节点" )
	private String fromNodeName;
	
	@Param(value="to_node_name",   ignored=true,   desc="终止节点" )
	private String toNodeName;
	
	@Param(value=CONDITION,   required=true,   maxlength=0,	desc="条件" )
	private String condition;
	
	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getRemarks() {
		return remarks;
	}

	public void setRemarks(String remarks) {
		this.remarks = remarks;
	}
	
	
	public Long getFlowDefId() {
		return this.flowDefId;
	}
	
	public void setFlowDefId(Long flowDefId) {
		this.flowDefId = flowDefId;
	}
	
	public Long getFromNodeId() {
		return this.fromNodeId;
	}
	
	public void setFromNodeId(Long fromNodeId) {
		this.fromNodeId = fromNodeId;
	}
	
	public Long getToNodeId() {
		return this.toNodeId;
	}
	
	public void setToNodeId(Long toNodeId) {
		this.toNodeId = toNodeId;
	}

	public String getCondition() {
		return condition;
	}

	public void setCondition(String condition) {
		this.condition = condition;
	}

	public String getFromNodeName() {
		return fromNodeName;
	}

	public void setFromNodeName(String fromNodeName) {
		this.fromNodeName = fromNodeName;
	}

	public String getToNodeName() {
		return toNodeName;
	}

	public void setToNodeName(String toNodeName) {
		this.toNodeName = toNodeName;
	}
	

}